Skip to content

HDDS-15034. Query SCM status for ozone admin upgrade status command#10084

Open
dombizita wants to merge 10 commits intoapache:HDDS-14496-zdufrom
dombizita:HDDS-15034
Open

HDDS-15034. Query SCM status for ozone admin upgrade status command#10084
dombizita wants to merge 10 commits intoapache:HDDS-14496-zdufrom
dombizita:HDDS-15034

Conversation

@dombizita
Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

After #10011 is merged the hardcoded placeholder responses can be removed and connect it to SCM for real values. Based on @errose28's suggestion I used HDDSLayoutVersionManager to check the finalization status of SCM and added a new counter to SCMNodeManager to keep track of the number of DNs finalized and used that for the ozone admin upgrade status output.

What is the link to the Apache JIRA

https://issues.apache.org/jira/browse/HDDS-15034

How was this patch tested?

Added tests, green CI on my fork: https://github.com/dombizita/ozone/actions/runs/24517013218

@dombizita dombizita requested review from errose28 and sodonnel April 17, 2026 09:13
@github-actions github-actions Bot added the zdu Pull requests for Zero Downtime Upgrade (ZDU) https://issues.apache.org/jira/browse/HDDS-14496 label Apr 17, 2026
@dombizita
Copy link
Copy Markdown
Contributor Author

Thank you for the review @sodonnel, addressed your comments in the latest commit.

@dombizita
Copy link
Copy Markdown
Contributor Author

Thanks @sodonnel, based on you comments and offline discussion I agree that it's safer and easier to just get the count each time while iterating through the nodes and not store it as a counter, which could go out of sync because of corner cases

Copy link
Copy Markdown
Contributor

@sodonnel sodonnel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This version looks good if we get green CI.

Copy link
Copy Markdown
Contributor

@errose28 errose28 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for working on this @dombizita. I don't think we are quite ready to merge yet.

Copy link
Copy Markdown
Contributor

@errose28 errose28 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Just one minor comment on the docs but we can add it to whatever PR comes next. @sodonnel would you like to check again before merging?


for (DatanodeDetails dn : getAllNodes()) {
try {
// Only count HEALTHY nodes. STALE/DEAD nodes are intentionally excluded
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can put this in the javadoc for the method to indicate the nodes it is operating on. Also we should document the reasoning for allowing all operational states.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

zdu Pull requests for Zero Downtime Upgrade (ZDU) https://issues.apache.org/jira/browse/HDDS-14496

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants